#pragma once

#include <QtWidgets/QMainWindow>
#include "ui__capture.h"
#include "_capture.h"
#include "include.h"
#include "Dialog.h"
#include <QDebug>
#include <iostream>
#include <string>
#include <winsock2.h>
#include <Windows.h>
#include <mstcpip.h>
#include<stdlib.h>
#include <QLabel>
#include <QLayout>
#include <QScrollArea>

//#include <string>
#include <pcap.h>

#pragma comment(lib,"ws2_32.lib")
#pragma comment(lib, "packet.lib")
#pragma comment(lib, "wpcap.lib")

#include "include.h"

//using namespace std;

#define DEFAULT_BUFLEN 4096
#define DEFAULT_NAMELEN 512

QT_BEGIN_NAMESPACE
namespace Ui { class _captureClass; };
QT_END_NAMESPACE

extern vector<const char*> pack_type;
extern vector<string> vadapters;
extern vector<vector<string>> vvheader;
extern vector<string> vdata;
class _capture : public QMainWindow
{
    Q_OBJECT

public:
    _capture(QWidget *parent = nullptr);
    ~_capture();
public slots:
    void on_pushButton_clicked();
    void on_table_cellPressed();
private:
    Ui::_captureClass *ui;
};

void FreeVector();

void MonitorAdapter(int nChoose, const char* Type, int count);
